/*
 Copyright (C) 2010 Emweb bvba, Kessel-Lo, Belgium.

 For terms of use, see LICENSE.
 Includes Array Remove - By John Resig (MIT Licensed)
 Includes normalizeWheel from Fixed Data Tables for React by Facebook (BSD Licensed)
 Includes jQuery Caret Range plugin
 Copyright (c) 2009 Matt Zabriskie
 Released under the MIT and GPL licenses.

 Includes Yahoo History Frameowork
 Copyright (c) 2008, Yahoo! Inc. All rights reserved.
 Code licensed under the BSD License:
 http://developer.yahoo.net/yui/license.txt
 version: 2.5.2
*/
_$_$if_DYNAMIC_JS_$_();window.JavaScriptFunction=1;window.JavaScriptConstructor=2;window.JavaScriptObject=3;window.JavaScriptPrototype=4;window.WT_DECLARE_WT_MEMBER=function(P,Q,J,S){if(Q==JavaScriptPrototype){P=J.indexOf(".prototype");_$_WT_CLASS_$_[J.substr(0,P)].prototype[J.substr(P+11)]=S}else _$_WT_CLASS_$_[J]=Q==JavaScriptFunction?function(){return S.apply(_$_WT_CLASS_$_,arguments)}:S};
window.WT_DECLARE_APP_MEMBER=function(P,Q,J,S){var ba=window.currentApp;if(Q==JavaScriptPrototype){P=J.indexOf(".prototype");ba[J.substr(0,P)].prototype[J.substr(P+11)]=S}else ba[J]=Q==JavaScriptFunction?function(){return S.apply(ba,arguments)}:S};_$_$endif_$_();
if(!window._$_WT_CLASS_$_)window._$_WT_CLASS_$_=new (function(){function P(a){return a.split("/")[2]}function Q(a){return 55296<=a&&a<=56319}function J(a){return 56320<=a&&a<=57343}function S(a,b){var e,g=a.start,k=a.end;for(e=0;e<b.length;++e){if(e>=a.start&&e>=a.end)return{start:g,end:k};if(Q(b.charCodeAt(e))&&e+1<b.length&&J(b.charCodeAt(e+1))){e<a.start&&--g;e<a.end&&--k}}return{start:g,end:k}}function ba(a,b,e){if(a=="auto"||a==null)return e;return(a=(a=b.exec(a))&&a.length==2?a[1]:null)?parseFloat(a):
e}function oa(a){if(T==null)return null;if(!a)a=window.event;if(a){for(var b=a=h.target(a);b&&b!=T;)b=b.parentNode;return b==T?h.isIElt9?a:null:T}else return T}function wa(a){var b=oa(a);if(b&&!V){if(!a)a=window.event;V=true;if(h.isIElt9){h.firedTarget=a.srcElement||b;b.fireEvent("onmousemove",a);h.firedTarget=null}else h.condCall(b,"onmousemove",a);return V=false}else return true}function ja(a){var b=oa(a);h.capture(null);if(b){if(!a)a=window.event;if(h.isIElt9){h.firedTarget=a.srcElement||b;b.fireEvent("onmouseup",
a);h.firedTarget=null}else h.condCall(b,"onmouseup",a);h.cancelEvent(a,h.CancelPropagate);return false}else return true}function pa(a){var b=oa(a);if(b&&!V){if(!a)a=window.event;V=true;if(h.isIElt9){h.firedTarget=a.srcElement||b;b.fireEvent("ontouchmove",a);h.firedTarget=null}else h.condCall(b,"ontouchmove",a);return V=false}else return true}function qa(a){var b=oa(a);h.capture(null);if(b){if(!a)a=window.event;if(h.isIElt9){h.firedTarget=a.srcElement||b;b.fireEvent("ontouchend",a);h.firedTarget=null}else h.condCall(b,
"ontouchend",a);h.cancelEvent(a,h.CancelPropagate);return false}else return true}function xa(a){if(a.addEventListener){a.addEventListener("mousemove",wa,true);a.addEventListener("mouseup",ja,true);h.isGecko&&window.addEventListener("mouseout",function(b){!b.relatedTarget&&h.hasTag(b.target,"HTML")&&ja(b)},true)}else{a.attachEvent("onmousemove",wa);a.attachEvent("onmouseup",ja)}}function Ka(a){if(a.addEventListener){a.addEventListener("touchmove",pa,true);a.addEventListener("touchend",qa,true)}else{a.attachEvent("ontouchmove",
pa);a.attachEvent("ontouchend",qa)}}function ya(){if(!ra){ra=true;var a=document.body;xa(a);Ka(a)}}function La(){if(!ca){var a,b,e=document.styleSheets;a=0;for(b=e.length;a<b;++a){var g=e[a];if(h.hasTag(e[a].ownerNode,"STYLE")){ca=g;break}}if(!ca){g=document.createElement("style");document.getElementsByTagName("head")[0].appendChild(g);ca=g.sheet}}return ca}function Ga(a){return a.replace(/%/g,"%25").replace(/\+/g,"%2b").replace(/ /g,"%20").replace(/&/g,"%26")}var h=this;this.condCall=function(a,
b,e){a[b]&&a[b](e)};var za=this.buttons=0,sa=0;this.button=function(a){try{var b=a.type;if(h.isIE&&(b=="click"||b=="dblclick"))return za;if(b!="mouseup"&&b!="mousedown"&&b!="click"&&b!="dblclick")return 0}catch(e){return 0}return h.isIElt9?a.button==2?4:a.button==4?2:a.button==1?1:0:a.button==0?1:a.button==1?2:a.button==2?4:0};this.mouseDown=function(a){h.buttons|=h.button(a)};this.mouseUp=function(a){za=h.button(a);h.buttons&=~za;setTimeout(function(){sa=0},5)};this.dragged=function(){return sa>
2};this.drag=function(){++sa};this.arrayRemove=function(a,b,e){e=a.slice((e||b)+1||a.length);a.length=b<0?a.length+b:b;return a.push.apply(a,e)};this.addAll=function(a,b){for(var e=0,g=b.length;e<g;++e)a.push(b[e])};var ka=function(){for(var a,b=3,e=document.createElement("div"),g=e.getElementsByTagName("i");e.innerHTML="<!--[if gt IE "+ ++b+"]><i></i><![endif]--\>",g[0];);return b>4?b:a}(),da=navigator.userAgent.toLowerCase();this.isIE=ka!==undefined;this.isIE6=ka===6;this.isIE8=ka===8;this.isIElt9=
ka<9;this.isIEMobile=da.indexOf("msie 4")!=-1||da.indexOf("msie 5")!=-1;this.isOpera=typeof window.opera!=="undefined";this.isAndroid=da.indexOf("safari")!=-1&&da.indexOf("android")!=-1;this.isWebKit=da.indexOf("applewebkit")!=-1;this.isGecko=da.indexOf("gecko")!=-1&&!this.isWebKit;this.updateDelay=this.isIE?10:51;if(this.isAndroid){console.error("init console.error");console.info("init console.info");console.log("init console.log");console.warn("init console.warn")}var la=new Date;this.trace=function(a,
b){if(b)la=new Date;b=new Date;b=(b.getMinutes()-la.getMinutes())*6E4+(b.getSeconds()-la.getSeconds())*1E3+(b.getMilliseconds()-la.getMilliseconds());window.console&&console.log("["+b+"]: "+a)};this.initAjaxComm=function(a,b){function e(k,n){var o=null,q=true;if(window.XMLHttpRequest){o=new XMLHttpRequest;if(g)if("withCredentials"in o){if(n){o.open(k,n,true);o.withCredentials="true"}}else if(typeof XDomainRequest!="undefined"){o=new XDomainRequest;if(n){q=false;try{o.open(k,n+"&contentType=x-www-form-urlencoded")}catch(u){o=
null}}}else o=null;else n&&o.open(k,n,true)}else if(!g&&window.ActiveXObject){try{o=new ActiveXObject("Msxml2.XMLHTTP")}catch(w){try{o=new ActiveXObject("Microsoft.XMLHTTP")}catch(x){}}n&&o&&o.open(k,n,true)}o&&n&&q&&o.setRequestHeader("Content-type","application/x-www-form-urlencoded");return o}var g=(a.indexOf("://")!=-1||a.indexOf("//")==0)&&P(a)!=window.location.host;return e("POST",a)!=null?new (function(){function k(o,q,u,w){function x(G){if(!H){clearTimeout(N);if(n){H=true;var ea=t;if(t){t.onreadystatechange=
new Function;try{t.onload=t.onreadystatechange}catch(s){}t=null}G?b(0,ea.responseText,q):b(1,null,q)}}}function B(){if(t.readyState==4){var G=t.status==200&&t.getResponseHeader("Content-Type")&&t.getResponseHeader("Content-Type").indexOf("text/javascript")==0;x(G)}}function z(){if(!H)if(n){t.onreadystatechange=new Function;t=null;H=true;b(2,null,q)}}var t=e("POST",n),N=null,H=false;this.abort=function(){if(t!=null){t.onreadystatechange=new Function;H=true;t.abort();t=null}};_$_CLOSE_CONNECTION_$_&&
t.setRequestHeader("Connection","close");if(w>0)N=setTimeout(z,w);t.onreadystatechange=B;try{t.onload=function(){x(true)};t.onerror=function(){x(false)}}catch(M){}t.send(o)}var n=a;this.responseReceived=function(){};this.sendUpdate=function(o,q,u,w){if(!n)return null;return new k(o,q,u,w)};this.cancel=function(){n=null};this.setUrl=function(o){n=o}}):new (function(){function k(q,u,w){function x(){b(1,null,u);B.parentNode.removeChild(B)}this.userData=u;var B=this.script=document.createElement("script");
B.id="script"+w;B.setAttribute("src",n+"&"+q);B.onerror=x;document.getElementsByTagName("head")[0].appendChild(B);this.abort=function(){B.parentNode.removeChild(B)}}var n=a,o=null;this.responseReceived=function(){if(o!=null){var q=o;o.script.parentNode.removeChild(o.script);o=null;b(0,"",q.userData)}};this.sendUpdate=function(q,u,w,x){if(!n)return null;return o=new k(q,u,w,x)};this.cancel=function(){n=null};this.setUrl=function(q){n=q}})};this.setHtml=function(a,b,e){function g(n,o){var q,u,w;switch(n.nodeType){case 1:q=
n.namespaceURI===null?document.createElement(n.nodeName):document.createElementNS(n.namespaceURI,n.nodeName);if(n.attributes&&n.attributes.length>0){u=0;for(w=n.attributes.length;u<w;)q.setAttribute(n.attributes[u].nodeName,n.getAttribute(n.attributes[u++].nodeName))}if(o&&n.childNodes.length>0){u=0;for(w=n.childNodes.length;u<w;){var x=g(n.childNodes[u++],o);x&&q.appendChild(x)}}return q;case 3:case 4:case 5:return document.createTextNode(n.nodeValue)}return null}if(h.isIE||_$_INNER_HTML_$_&&!e)if(e)a.innerHTML+=
b;else{h.saveReparented(a);a.innerHTML=b}else{var k;k=new DOMParser;k=k.parseFromString("<div>"+b+"</div>","application/xhtml+xml").documentElement;if(k.nodeType!=1)k=k.nextSibling;if(!e){h.saveReparented(a);a.innerHTML=""}b=0;for(e=k.childNodes.length;b<e;)a.appendChild(g(k.childNodes[b++],true))}};this.hasTag=function(a,b){return a.nodeType==1&&a.tagName&&a.tagName.toUpperCase()===b};this.insertAt=function(a,b,e){if(a.childNodes.length){var g,k,n;k=g=0;for(n=a.childNodes.length;g<n;++g)if(!$(a.childNodes[g]).hasClass("wt-reparented")){if(k===
e){a.insertBefore(b,a.childNodes[g]);return}++k}}a.appendChild(b)};this.remove=function(a){if(a=h.getElement(a)){h.saveReparented(a);a.parentNode.removeChild(a)}};this.replaceWith=function(a,b){$("#"+a).replaceWith(b);b.get(0).wtValidate&&h.validate&&setTimeout(function(){h.validate(b.get(0))},0)};this.contains=function(a,b){for(b=b.parentNode;b&&!h.hasTag(b,"BODY");){if(b==a)return true;b=b.parentNode}return false};this.unstub=function(a,b,e){if(e==1){if(a.style.display!="none")b.style.display=a.style.display}else{b.style.position=
a.style.position;b.style.left=a.style.left;b.style.visibility=a.style.visibility}if(a.style.height)b.style.height=a.style.height;if(a.style.width)b.style.width=a.style.width;b.style.boxSizing=a.style.boxSizing;e=h.styleAttribute("box-sizing");if(h.vendorPrefix(e))b.style[e]=a.style[e]};this.saveReparented=function(a){$(a).find(".wt-reparented").each(function(){$(".Wt-domRoot").get(0).appendChild(this.parentNode.removeChild(this))})};this.changeTag=function(a,b){var e=document.createElement(b);if(b==
"img"&&e.mergeAttributes){e.mergeAttributes(a,false);e.src=a.src}else if(a.attributes&&a.attributes.length>0){var g;b=0;for(g=a.attributes.length;b<g;b++){var k=a.attributes[b].nodeName;k!="type"&&k!="name"&&e.setAttribute(k,a.getAttribute(k))}}for(;a.firstChild;)e.appendChild(a.removeChild(a.firstChild));a.parentNode.replaceChild(e,a)};this.unwrap=function(a){a=h.getElement(a);if(a.parentNode.className.indexOf("Wt-wrap")){if(a.getAttribute("type")=="submit"){a.setAttribute("type","button");a.removeAttribute("name")}else if(h.hasTag(a,
"A")&&a.href.indexOf("&signal=")!=-1)a.href="javascript:void(0)";h.hasTag(a,"INPUT")&&a.getAttribute("type")=="image"&&h.changeTag(a,"img")}else{var b=a;a=a.parentNode;if(a.className.length>=8)b.className=a.className.substring(8);var e=a.getAttribute("style");if(e)h.isIE?b.style.setAttribute("cssText",e):b.setAttribute("style",e);a.parentNode.replaceChild(b,a)}};this.navigateInternalPath=function(a,b){a=a||window.event;if(!a.ctrlKey&&!a.metaKey&&h.button(a)<=1){h.history.navigate(b,true);h.cancelEvent(a,
h.CancelDefaultAction)}};this.ajaxInternalPaths=function(a){$(".Wt-ip").each(function(){var b=this.getAttribute("href"),e=b.lastIndexOf("?wtd");if(e===-1)e=b.lastIndexOf("&wtd");if(e!==-1)b=b.substr(0,e);var g;if(b.indexOf("://")!=-1){e=document.createElement("div");e.innerHTML='<a href="'+a+'">x</a>';g=b.substr(e.firstChild.href.length-1)}else{for(;b.substr(0,3)=="../";)b=b.substr(3);if(b.charAt(0)!="/")b="/"+b;g=b.substr(a.length);if(g.substr(0,2)=="_="&&a.charAt(a.length-1)=="?")g="?"+g}if(g.length==
0||g.charAt(0)!="/")g="/"+g;if(g.substr(0,4)=="/?_=")g=g.substr(4);this.setAttribute("href",b);this.setAttribute("href",this.href);this.onclick=function(k){h.navigateInternalPath(k,g)};$(this).removeClass("Wt-ip")})};this.resolveRelativeAnchors=function(){window.$&&$(".Wt-rr").each(function(){this.href&&this.setAttribute("href",this.href);this.src&&this.setAttribute("src",this.src);$(this).removeClass("Wt-rr")})};var V=false;this.CancelPropagate=1;this.CancelDefaultAction=2;this.CancelAll=3;this.cancelEvent=
function(a,b){if(!V){b=b===undefined?h.CancelAll:b;if(b&h.CancelDefaultAction)if(a.preventDefault)a.preventDefault();else a.returnValue=false;if(b&h.CancelPropagate)if(a.stopPropagation)a.stopPropagation();else a.cancelBubble=true}};this.$=this.getElement=function(a){var b=document.getElementById(a);if(!b)for(var e=0;e<window.frames.length;++e)try{if(b=window.frames[e].document.getElementById(a))return b}catch(g){}return b};this.filter=function(a,b,e){a=String.fromCharCode(typeof b.charCode!=="undefined"?
b.charCode:b.keyCode);(new RegExp(e)).test(a)||h.cancelEvent(b)};this.widgetPageCoordinates=function(a,b){var e=0,g=0,k;if(!a.parentNode)return{x:0,y:0};if(h.hasTag(a,"AREA"))a=a.parentNode.nextSibling;for(var n=$(document.body).hasClass("Wt-rtl");a&&a!==b;){e+=a.offsetLeft;g+=a.offsetTop;if(h.css(a,"position")=="fixed"){e+=document.body.scrollLeft+document.documentElement.scrollLeft;g+=document.body.scrollTop+document.documentElement.scrollTop;break}k=a.offsetParent;if(k==null)a=null;else{do{a=a.parentNode;
if(h.hasTag(a,"DIV")){if(n&&!h.isGecko){if(a.scrollWidth>a.parentNode.scrollWidth)e-=a.scrollLeft+a.parentNode.scrollWidth-a.scrollWidth}else e-=a.scrollLeft;g-=a.scrollTop}}while(a!=null&&a!=k)}}return{x:e,y:g}};this.widgetCoordinates=function(a,b){b=h.pageCoordinates(b);a=h.widgetPageCoordinates(a);return{x:b.x-a.x,y:b.y-a.y}};this.pageCoordinates=function(a){if(!a)a=window.event;var b=0,e=0,g=a.target||a.srcElement;if(g&&g.ownerDocument!=document)for(var k=0;k<window.frames.length;k++)if(g.ownerDocument==
window.frames[k].document)try{var n=window.frames[k].frameElement.getBoundingClientRect();b=n.left;e=n.top}catch(o){}if(a.touches&&a.touches[0])return h.pageCoordinates(a.touches[0]);else if(!h.isIE&&a.changedTouches&&a.changedTouches[0]){b+=a.changedTouches[0].pageX;e+=a.changedTouches[0].pageY}else if(typeof a.pageX==="number"){b+=a.pageX;e=a.pageY}else if(typeof a.clientX==="number"){b+=a.clientX+document.body.scrollLeft+document.documentElement.scrollLeft;e+=a.clientY+document.body.scrollTop+
document.documentElement.scrollTop}return{x:b,y:e}};this.windowCoordinates=function(a){a=h.pageCoordinates(a);return{x:a.x-document.body.scrollLeft-document.documentElement.scrollLeft,y:a.y-document.body.scrollTop-document.documentElement.scrollTop}};this.normalizeWheel=function(a){var b=0,e=0,g=0,k=0;if("detail"in a)e=a.detail;if("wheelDelta"in a)e=-a.wheelDelta/120;if("wheelDeltaY"in a)e=-a.wheelDeltaY/120;if("wheelDeltaX"in a)b=-a.wheelDeltaX/120;if("axis"in a&&a.axis===a.HORIZONTAL_AXIS){b=e;
e=0}g=b*10;k=e*10;if("deltaY"in a)k=a.deltaY;if("deltaX"in a)g=a.deltaX;if((g||k)&&a.deltaMode)if(a.deltaMode==1){g*=40;k*=40}else{g*=800;k*=800}if(g&&!b)b=g<1?-1:1;if(k&&!e)e=k<1?-1:1;return{spinX:b,spinY:e,pixelX:g,pixelY:k}};this.wheelDelta=function(a){var b=0;if(a.deltaY)b=a.deltaY>0?-1:1;else if(a.wheelDelta)b=a.wheelDelta>0?1:-1;else if(a.detail)b=a.detail<0?1:-1;return b};this.scrollIntoView=function(a){setTimeout(function(){var b=a.indexOf("#");if(b!=-1)a=a.substr(b+1);var e=document.getElementById(a);
if(e){for(b=e.parentNode;b!=document.body;b=b.parentNode)if(b.scrollHeight>b.clientHeight&&h.css(b,"overflow-y")=="auto"){e=h.widgetPageCoordinates(e,b);b.scrollTop+=e.y;return}e.scrollIntoView(true)}},100)};this.getUnicodeSelectionRange=function(a){return S(h.getSelectionRange(a),$(a).val())};this.getSelectionRange=function(a){if(document.selection)if(h.hasTag(a,"TEXTAREA")){var b=document.selection.createRange(),e=b.duplicate();e.moveToElementText(a);var g=0;if(b.text.length>1){g-=b.text.length;
if(g<0)g=0}a=-1+g;for(e.moveStart("character",g);e.inRange(b);){e.moveStart("character");a++}b=b.text.replace(/\r/g,"");return{start:a,end:b.length+a}}else{e=b=-1;if(a=$(a).val()){e=document.selection.createRange().duplicate();e.moveEnd("character",a.length);b=e.text==""?a.length:a.lastIndexOf(e.text);e=document.selection.createRange().duplicate();e.moveStart("character",-a.length);e=e.text.length}return{start:b,end:e}}else return a.selectionStart||a.selectionStart==0?{start:a.selectionStart,end:a.selectionEnd}:
{start:-1,end:-1}};this.setUnicodeSelectionRange=function(a,b,e){return h.setSelectionRange(a,b,e,true)};this.setSelectionRange=function(a,b,e,g){var k=$(a).val();if(typeof b!="number")b=-1;if(typeof e!="number")e=-1;if(b<0)b=0;if(e>k.length)e=k.length;if(e<b)e=b;if(b>e)b=e;a.focus();if(g)for(g=0;g<k.length;++g){if(g>=b&&g>=e)break;if(Q(k.charCodeAt(g))&&g+1<k.length&&J(k.charCodeAt(g+1))){g<b&&++b;g<e&&++e}}if(typeof a.selectionStart!=="undefined"){a.selectionStart=b;a.selectionEnd=e}else if(document.selection){a=
a.createTextRange();a.collapse(true);a.moveStart("character",b);a.moveEnd("character",e-b);a.select()}};this.isKeyPress=function(a){if(!a)a=window.event;if(a.altKey||a.ctrlKey||a.metaKey)return false;return(typeof a.charCode!=="undefined"?a.charCode:0)>0||h.isIE?true:h.isOpera?a.keyCode==13||a.keyCode==27||a.keyCode>=32&&a.keyCode<125:a.keyCode==13||a.keyCode==27||a.keyCode==32||a.keyCode>46&&a.keyCode<112};var fa=null,ga=null;this.isDblClick=function(a,b){if(a.wtClickTimeout&&Math.abs(a.wtE1.clientX-
b.clientX)<3&&Math.abs(a.wtE1.clientY-b.clientY)<3){clearTimeout(a.wtClickTimeout);a.wtClickTimeout=null;a.wtE1=null;return true}else return false};this.eventRepeat=function(a,b,e){h.stopRepeat();b=b||500;e=e||50;a();fa=setTimeout(function(){fa=null;a();ga=setInterval(a,e)},b)};this.stopRepeat=function(){if(fa){clearTimeout(fa);fa=null}if(ga){clearInterval(ga);ga=null}};var Aa=null,Ba=null;this.css=function(a,b){if(a.style[b])return a.style[b];else{if(a!==Aa){Aa=a;Ba=window.getComputedStyle?window.getComputedStyle(a,
null):a.currentStyle?a.currentStyle:null}return Ba?Ba[b]:null}};this.parsePx=function(a){return ba(a,/^\s*(-?\d+(?:\.\d+)?)\s*px\s*$/i,0)};this.parsePct=function(a,b){return ba(a,/^\s*(-?\d+(?:\.\d+)?)\s*\%\s*$/i,b)};this.px=function(a,b){return h.parsePx(h.css(a,b))};this.pxself=function(a,b){return h.parsePx(a.style[b])};this.pctself=function(a,b){return h.parsePct(a.style[b],0)};this.styleAttribute=function(a){function b(q){for(var u=q.search(/-./);u!=-1;){u=q.charAt(u+1).toUpperCase();q=q.replace(/-./,
u);u=q.search(/-./)}return q}var e=["","-moz-","-webkit-","-o-","-ms-"],g=document.createElement("div"),k,n;k=0;for(n=e.length;k<n;++k){var o=b(e[k]+a);if(o in g.style)return o}return b(a)};this.vendorPrefix=function(a){var b=["Moz","Webkit","O","Ms"];i=0;for(il=b.length;i<il;++i)if(a.search(b[i])!=-1)return b[i];return""};this.boxSizing=function(a){return h.css(a,h.styleAttribute("box-sizing"))==="border-box"};this.isHidden=function(a){if(a.style.display=="none"||$(a).hasClass("out"))return true;
else return(a=a.parentNode)&&!h.hasTag(a,"BODY")?h.isHidden(a):false};this.innerWidth=function(a){var b=a.offsetWidth;h.boxSizing(a)||(b-=h.px(a,"paddingLeft")+h.px(a,"paddingRight")+h.px(a,"borderLeftWidth")+h.px(a,"borderRightWidth"));return b};this.innerHeight=function(a){var b=a.offsetHeight;h.boxSizing(a)||(b-=h.px(a,"paddingTop")+h.px(a,"paddingBottom")+h.px(a,"borderTopWidth")+h.px(a,"borderBottomWidth"));return b};this.IEwidth=function(a,b,e){if(a.parentNode){var g=a.parentNode.clientWidth-
h.px(a,"marginLeft")-h.px(a,"marginRight")-h.px(a,"borderLeftWidth")-h.px(a,"borderRightWidth")-h.px(a.parentNode,"paddingLeft")-h.px(a.parentNode,"paddingRight");b=h.parsePct(b,0);e=h.parsePct(e,1E5);return g<b?b-1:g>e?e+1:a.style.styleFloat!=""?b-1:"auto"}else return"auto"};this.hide=function(a){h.getElement(a).style.display="none"};this.inline=function(a){h.getElement(a).style.display="inline"};this.block=function(a){h.getElement(a).style.display="block"};this.show=function(a){h.getElement(a).style.display=
""};var T=null;this.firedTarget=null;this.target=function(a){try{return h.firedTarget||a.target||a.srcElement}catch(b){return null}};var ra=false;this.capture=function(a){ya();if(!(T&&a)){for(var b=0;b<window.frames.length;b++)try{if(!window.frames[b].document.body.hasMouseHandlers){xa(window.frames[b].document.body);window.frames[b].document.body.hasMouseHandlers=true}}catch(e){}T=a;b=document.body;document.body.addEventListener||(a!=null?b.setCapture():b.releaseCapture());if(a!=null){$(b).addClass("unselectable");
b.setAttribute("unselectable","on");b.onselectstart="return false;"}else{$(b).removeClass("unselectable");b.setAttribute("unselectable","off");b.onselectstart=""}}};this.checkReleaseCapture=function(a,b){if(b&&T&&a==T&&(b.type=="mouseup"||b.type=="touchend"))this.capture(null)};this.getElementsByClassName=function(a,b){if(document.getElementsByClassName)return b.getElementsByClassName(a);else{b=b.getElementsByTagName("*");for(var e=[],g,k=0,n=b.length;k<n;k++){g=b[k];g.className.indexOf(a)!=-1&&e.push(g)}return e}};
var ca=null;this.addCss=function(a,b){var e=La();e.insertRule(a+" { "+b+" }",e.cssRules?e.cssRules.length:0)};this.addCssText=function(a){var b=document.getElementById("Wt-inline-css");if(!b){b=document.createElement("style");b.id="Wt-inline-css";document.getElementsByTagName("head")[0].appendChild(b)}if(b.styleSheet){var e=b.previousSibling;if(!e||!h.hasTag(e,"STYLE")||e.styleSheet.cssText.length>32768){e=document.createElement("style");b.parentNode.insertBefore(e,b);e.styleSheet.cssText=a}else e.styleSheet.cssText+=
a}else{a=document.createTextNode(a);b.appendChild(a)}};this.getCssRule=function(a,b){a=a.toLowerCase();if(document.styleSheets)for(var e=0;e<document.styleSheets.length;e++){var g=document.styleSheets[e],k=0,n;do{n=null;try{if(g.cssRules)n=g.cssRules[k];else if(g.rules)n=g.rules[k];if(n&&n.selectorText)if(n.selectorText.toLowerCase()==a)if(b=="delete"){g.cssRules?g.deleteRule(k):g.removeRule(k);return true}else return n}catch(o){}++k}while(n)}return false};this.removeCssRule=function(a){return h.getCssRule(a,
"delete")};this.addStyleSheet=function(a,b){if(document.createStyleSheet)setTimeout(function(){document.createStyleSheet(a)},15);else{var e=document.createElement("link");e.setAttribute("href",a);e.setAttribute("type","text/css");e.setAttribute("rel","stylesheet");b!=""&&b!="all"&&e.setAttribute("media",b);b=document.getElementsByTagName("link");if(b.length>0){b=b[b.length-1];b.parentNode.insertBefore(e,b.nextSibling)}else document.body.appendChild(e)}};this.removeStyleSheet=function(a){$('link[rel=stylesheet][href~="'+
a+'"]')&&$('link[rel=stylesheet][href~="'+a+'"]').remove();for(var b=document.styleSheets,e=0;e<b.length;++e){var g=b[e];j=0;if(g){var k=null;do{try{if((k=g.cssRules?g.cssRules[j]:g.rules[j])&&k.cssText==='@import url("'+a+'");'){g.cssRules?g.deleteRule(j):g.removeRule(j);break}}catch(n){}++j}while(k)}}};this.windowSize=function(){var a,b;if(typeof window.innerWidth==="number"){a=window.innerWidth;b=window.innerHeight}else{a=document.documentElement.clientWidth;b=document.documentElement.clientHeight}return{x:a,
y:b}};this.fitToWindow=function(a,b,e,g,k){var n=["left","right"],o=["top","bottom"];a.style[n[0]]=a.style[n[1]]="auto";a.style[o[0]]=a.style[o[1]]="auto";var q=a.offsetWidth,u=a.offsetHeight,w=h.windowSize(),x=document.body.scrollLeft+document.documentElement.scrollLeft,B=document.body.scrollTop+document.documentElement.scrollTop;if(!$(a).hasClass("Wt-tooltip")){q=h.px(a,"maxWidth")||q;u=h.px(a,"maxHeight")||u}var z=a.offsetParent;if(z){var t=h.widgetPageCoordinates(z);if(q>w.x){b=x;g=0}else if(b+
q>x+w.x){q=z.scrollLeft;if(z==document.body)q=z.clientWidth-w.x;g=g-t.x+q;b=z.clientWidth-(g+h.px(a,"marginRight"));g=1}else{q=z.scrollLeft;if(z==document.body)q=0;b=b-t.x+q;b-=h.px(a,"marginLeft");g=0}if(u>w.y){e=B;k=0}else if(e+u>B+w.y){if(k>B+w.y)k=B+w.y;u=z.scrollTop;if(z==document.body)u=z.clientHeight-w.y;k=k-t.y+u;e=z.clientHeight-(k+h.px(a,"marginBottom")+h.px(a,"borderBottomWidth"));k=1}else{u=z.scrollTop;if(z==document.body)u=0;e=e-t.y+u;e=e-h.px(a,"marginTop")+h.px(a,"borderTopWidth");
k=0}a.style[n[g]]=b+"px";a.style[o[k]]=e+"px"}};this.positionXY=function(a,b,e){a=h.getElement(a);if(!h.isHidden(a)){a.style.display="block";h.fitToWindow(a,b,e,b,e)}};this.Horizontal=1;this.Vertical=2;this.positionAtWidget=function(a,b,e,g){a=h.getElement(a);var k=h.getElement(b);g||(g=0);if(k&&a){var n=h.widgetPageCoordinates(k),o;a.style.position="absolute";if(h.css(a,"display")=="none")a.style.display="block";if(e===h.Horizontal){e=n.x+k.offsetWidth;b=n.y+g;o=n.x;g=n.y+k.offsetHeight-g}else{e=
n.x;b=n.y+k.offsetHeight;o=n.x+k.offsetWidth;g=n.y}if(!a.wtNoReparent&&!$(a).hasClass("wt-no-reparent")){n=$(".Wt-domRoot").get(0);a.parentNode.removeChild(a);for(k=k.parentNode;k!=n;k=k.parentNode){if(k.wtResize)break;if(h.css(k,"display")!="inline"&&k.clientHeight>100&&(k.scrollHeight>k.clientHeight||k.scrollWidth>k.clientWidth))break}n=h.css(k,"position");if(n!="absolute"&&n!="relative")k.style.position="relative";k.appendChild(a);$(a).addClass("wt-reparented")}h.fitToWindow(a,e,b,o,g);a.style.visibility=
""}};this.hasFocus=function(a){try{return a===document.activeElement}catch(b){return false}};this.progressed=function(a){var b=document,e=b.body,g=this.getElement("Wt-form");a.style.display=g.style.display;g.parentNode.replaceChild(a,g);e.removeEventListener?e.removeEventListener("click",delayClick,true):e.detachEvent("click",delayClick);setTimeout(function(){var k,n;k=0;for(n=delayedClicks.length;k<n;++k)if(b.createEvent){var o=delayedClicks[k],q=b.createEvent("MouseEvents");q.initMouseEvent("click",
o.bubbles,o.cancelable,window,o.detail,o.screenX,o.screenY,o.clientX,o.clientY,o.ctrlKey,o.altKey,o.shiftKey,o.metaKey,o.button,null);(o=h.getElement(o.targetId))&&o.dispatchEvent(q)}else{o=delayedClicks[k];q=b.createEventObject();for(k in o)q[k]=o[k];(o=h.getElement(o.targetId))&&o.fireEvent("onclick",q)}},0)};this.history=window.history&&window.history.pushState?function(){function a(q){n[o.location.pathname+o.location.search]=q}var b=null,e=null,g=false,k=null,n={},o=window;return{_initialize:function(){},
_initTimeout:function(){},register:function(q,u){function w(x){x=x.state;if(x==null)x=n[o.location.pathname+o.location.search];if(x==null){x=o.location.pathname.lastIndexOf(b);if(x!=-1&&x==o.location.pathname.length-b.length){a(b);return}else x=o.location.pathname.substr(e.length)}if(x!=b){b=x;u(b!=""?b:"/")}}b=q;k=u;a(q);o.addEventListener("popstate",w,false)},initialize:function(q,u,w){h.resolveRelativeAnchors();e=w;if(e.length>=1&&e[e.length-1]=="/"){_$_$if_UGLY_INTERNAL_PATHS_$_();g=true;_$_$endif_$_();
_$_$ifnot_UGLY_INTERNAL_PATHS_$_();e=e.substr(0,e.length-1);_$_$endif_$_()}},navigate:function(q,u){h.resolveRelativeAnchors();b=q;var w=Ga(q),x=e;if(w.length!=0)x+=(g?"?_=":"")+w;if(g){function B(t){if(t.length>1)t=t.substr(1);var N=t.split("&"),H,M;t="";H=0;for(M=N.length;H<M;++H)if(N[H].split("=")[0]!="_")t+=(t.length?"&":"?")+N[H];return t}w=B(window.location.search);if(w.length>1){if(w.length>2&&w[0]=="?"&&w[1]=="&")w=w.substr(1);x+=x.indexOf("?")==-1?"?"+w.substr(1):"&"+w.substr(1)}}else x+=
window.location.search;try{window.history.pushState(q?q:"",document.title,x)}catch(z){console.log(z.toString())}h.scrollIntoView(q);u&&k(q)},getCurrentState:function(){return b}}}():h.isIE8?function(){var a=null,b=null,e=window;return{_initialize:function(){},_initTimeout:function(){},register:function(g,k){function n(){if(a!=e.location.hash){a=e.location.hash.substring(1);b(a)}}a=g;b=k;e.onhashchange=n},initialize:function(){},navigate:function(g,k){a=g;e.location.hash=g;h.scrollIntoView(g);k&&b(g)},
getCurrentState:function(){return a}}}():function(){function a(){var s,A;A=location.href;s=A.indexOf("#");return s>=0?A.substr(s+1):null}function b(){z.value=M+"|"+G}function e(){var s,A;s=0;for(A=ea.length;s<A;++s)ea[s](unescape(G))}function g(s){if(s){if(!s||G!==s){G=s||M;e()}}else{G=M;e()}}function k(s){var A;s='<html><body><div id="state">'+s+"</div></body></html>";try{A=B.contentWindow.document;A.open();A.write(s);A.close();return true}catch(E){return false}}function n(){var s,A,E,r;if(!B.contentWindow||
!B.contentWindow.document)setTimeout(n,10);else{s=B.contentWindow.document;E=(A=s.getElementById("state"))?A.innerText:null;r=a();setInterval(function(){var ta,O;s=B.contentWindow.document;ta=(A=s.getElementById("state"))?A.innerText:null;O=a();if(ta!==E){E=ta;g(E);O=E?E:M;if(location.hash!=O&&location.hash.substring(1)!=O)location.hash=O;r=O;b()}else if(O!==r){r=O;k(O)}},50);t=true;x!=null&&x()}}function o(){if(!u){var s=a(),A=history.length;N&&clearInterval(N);N=setInterval(function(){var E,r;E=
a();r=history.length;if(E!==s){s=E;A=r;g(s);b()}},50)}}function q(){var s;s=z.value.split("|");if(s.length>1){M=s[0];G=s[1]}else M=G="";if(s.length>2)H=s[2].split(",");if(u)n();else{o();t=true;x!=null&&x()}}var u=h.isIElt9,w=false,x=null,B=null,z=null,t=false,N=null,H=[],M,G,ea=[];return{_initialize:function(){z!=null&&q()},_initTimeout:function(){o()},register:function(s,A){if(!t)G=M=escape(s);ea.push(A)},initialize:function(s,A){if(!t){if((navigator.vendor||"")!=="KDE")if(typeof window.opera!==
"undefined")w=true;if(typeof s==="string")s=document.getElementById(s);if(!(!s||s.tagName.toUpperCase()!=="TEXTAREA"&&(s.tagName.toUpperCase()!=="INPUT"||s.type!=="hidden"&&s.type!=="text"))){z=s;if(u){if(typeof A==="string")A=document.getElementById(A);!A||A.tagName.toUpperCase()!=="IFRAME"||(B=A)}}}},navigate:function(s,A){s=Ga(s);if(t){s=s;if(u)k(s);else if(s.length>0)location.hash=s;A&&e()}},getCurrentState:function(){if(!t)return"";return unescape(G)}}}()});if(window._$_APP_CLASS_$_&&window._$_APP_CLASS_$_._p_)try{window._$_APP_CLASS_$_._p_.quit(null)}catch(e$$35){}
window._$_APP_CLASS_$_=new (function(){function P(d){d=r.pageCoordinates(d);ta=d.x;O=d.y}function Q(){var d=_$_WT_CLASS_$_.history.getCurrentState();if(!(d!=null&&d.length>0&&d.substr(0,1)!="/"))if(ha!=d){ha=d;setTimeout(function(){ra(null,"hash",null,true)},1)}}function J(d,c){if(!(ha==d||!ha&&d=="/")){c||(ha=d);r.history.navigate(d,c)}}function S(){document.body.ondragstart=function(){return false}}function ba(d,c){Ca=setTimeout(function(){wa(d,c)},Xa)}function oa(){Ca&&clearTimeout(Ca)}function wa(d,
c){if(c.touches)if("vibrate"in navigator){navigator.vibrate=navigator.vibrate||navigator.webkitVibrate||navigator.mozVibrate||navigator.msVibrate;navigator.vibrate&&navigator.vibrate(100)}if((c.ctrlKey||r.button(c)>1)&&!c.touches)return true;var f=r.target(c);if(f)if(r.css(f,"display")!=="inline"&&(f.offsetWidth>f.clientWidth||f.offsetHeight>f.clientHeight)){var l=r.widgetPageCoordinates(f),p=r.pageCoordinates(c),m=p.y-l.y;if(p.x-l.x>f.clientWidth||m>f.clientHeight)return true}f=Ha;f.object=r.getElement(d.getAttribute("dwid"));
if(f.object==null)return true;f.sourceId=d.getAttribute("dsid");f.objectPrevStyle={position:f.object.style.position,display:f.object.style.display,left:f.object.style.left,top:f.object.style.top,className:f.object.className,parent:f.object.parentNode,zIndex:f.object.zIndex};f.object.parentNode.removeChild(f.object);f.object.style.position="absolute";f.object.className=f.objectPrevStyle.className+"";f.object.style.zIndex="1000";document.body.appendChild(f.object);r.capture(null);r.capture(f.object);
f.object.onmousemove=ja;f.object.onmouseup=pa;f.object.ontouchmove=ja;f.object.ontouchend=pa;f.offsetX=-4;f.offsetY=-4;f.dropTarget=null;f.mimeType=d.getAttribute("dmt");f.xy=r.pageCoordinates(c);r.cancelEvent(c,r.CancelPropagate);return false}function ja(d){d=d||window.event;if(Ha.object!==null){var c=Ha,f=r.pageCoordinates(d);if(c.object.style.display!==""&&c.xy.x!==f.x&&c.xy.y!==f.y)c.object.style.display="";c.object.style.left=f.x-c.offsetX+"px";c.object.style.top=f.y-c.offsetY+"px";f=c.dropTarget;
var l;if(d.changedTouches){c.object.style.display="none";l=document.elementFromPoint(d.changedTouches[0].clientX,d.changedTouches[0].clientY);c.object.style.display=""}else{l=r.target(d);if(l==c.object)if(document.elementFromPoint){c.object.style.display="none";l=document.elementFromPoint(d.clientX,d.clientY);c.object.style.display=""}}var p="{"+c.mimeType+":",m=null;for(c.dropTarget=null;l;){m=l.getAttribute("amts");if(m!=null&&m.indexOf(p)!=-1){c.dropTarget=l;break}l=l.parentNode;if(!l.tagName||
r.hasTag(l,"HTML"))break}if(c.dropTarget!=f){if(c.dropTarget){l=m.indexOf(p)+p.length;var v=m.indexOf("}",l);m=m.substring(l,v);if(m.length!=0){c.dropTarget.setAttribute("dos",c.dropTarget.className);c.dropTarget.className=c.dropTarget.className+" "+m}}else c.object.styleClass="";if(f!=null){f.handleDragDrop&&f.handleDragDrop("end",c.object,d,"",p);m=f.getAttribute("dos");if(m!=null)f.className=m}}if(c.dropTarget)if(c.dropTarget.handleDragDrop)c.dropTarget.handleDragDrop("drag",c.object,d,"",p);else c.object.className=
c.objectPrevStyle.className+" Wt-valid-drop";else c.object.className=c.objectPrevStyle.className+"";return false}return true}function pa(d){d=d||window.event;r.capture(null);var c=Ha;if(c.object){if(c.dropTarget){var f=c.dropTarget.getAttribute("dos");if(f!=null)c.dropTarget.className=f;if(c.dropTarget.handleDragDrop)c.dropTarget.handleDragDrop("drop",c.object,d,c.sourceId,c.mimeType);else d.touches?q(c.dropTarget,{name:"_drop2",eventObject:c.dropTarget,event:d},c.sourceId,c.mimeType):q(c.dropTarget,
{name:"_drop",eventObject:c.dropTarget,event:d},c.sourceId,c.mimeType)}document.body.removeChild(c.object);c.objectPrevStyle.parent.appendChild(c.object);c.object.style.zIndex=c.objectPrevStyle.zIndex;c.object.style.position=c.objectPrevStyle.position;c.object.style.display=c.objectPrevStyle.display;c.object.style.left=c.objectPrevStyle.left;c.object.style.top=c.objectPrevStyle.top;c.object.className=c.objectPrevStyle.className;c.object=null;Ca&&clearTimeout(Ca)}}function qa(d,c,f){var l,p;p=d+"=";
d=0;for(l=c.length;d<l;++d){var m=c[d];if(d!=0)p+=";";p+=[m.identifier,Math.round(m.clientX),Math.round(m.clientY),Math.round(m.pageX),Math.round(m.pageY),Math.round(m.screenX),Math.round(m.screenY),Math.round(m.pageX-f.x),Math.round(m.pageY-f.y)].join(";")}return p}function xa(d,c){var f,l;l=d.event;c=c>0?"&e"+c:"&";f=c+"signal="+d.signal;if(d.id){f+=c+"id="+d.id+c+"name="+encodeURIComponent(d.name)+c+"an="+d.args.length;for(var p=0;p<d.args.length;++p)f+=c+"a"+p+"="+encodeURIComponent(d.args[p])}for(var m=
0;m<Da.length;++m){var v=r.getElement(Da[m]),C=null,U;if(v!=null){if(v.wtEncodeValue)C=v.wtEncodeValue(v);else if(v.type=="select-multiple"){p=0;for(U=v.options.length;p<U;p++)if(v.options[p].selected)f+=c+Da[m]+"="+encodeURIComponent(v.options[p].value)}else if(v.type=="checkbox"||v.type=="radio")if(v.indeterminate||v.style.opacity=="0.5")C="i";else{if(v.checked)C=v.value}else if(v.type!="file"){if($(v).hasClass("Wt-edit-emptyText"))C="";else{v.ed&&v.ed.save();C=""+v.value}if(r.hasFocus(v)){p=r.getUnicodeSelectionRange(v);
f+=c+"selstart="+p.start+c+"selend="+p.end}}if(C!=null)f+=c+Da[m]+"="+encodeURIComponent(C)}}try{if(document.activeElement)f+=c+"focus="+document.activeElement.id}catch(Y){}if(ha!=null)f+=c+"_="+encodeURIComponent(ha);if(!l){d.data=f;return d}for(m=r.target(l);m&&!m.id&&m.parentNode;)m=m.parentNode;if(m&&m.id)f+=c+"tid="+m.id;try{if(typeof l.type==="string")f+=c+"type="+l.type}catch(Ya){}if(typeof l.clientX!=="undefined"&&typeof l.clientX!=="unknown")f+=c+"clientX="+Math.round(l.clientX)+c+"clientY="+
Math.round(l.clientY);C=r.pageCoordinates(l);m=C.x;p=C.y;if(m||p){f+=c+"documentX="+Math.round(m)+c+"documentY="+Math.round(p);f+=c+"dragdX="+Math.round(m-ta)+c+"dragdY="+Math.round(p-O);C=r.wheelDelta(l);f+=c+"wheel="+Math.round(C)}if(typeof l.screenX!=="undefined"&&typeof l.screenX!=="unknown")f+=c+"screenX="+Math.round(l.screenX)+c+"screenY="+Math.round(l.screenY);C={x:0,y:0};if(d.object&&d.object.nodeType!=9){C=r.widgetPageCoordinates(d.object);v=C.x;U=C.y;if(typeof d.object.scrollLeft!=="undefined"&&
typeof d.object.scrollLeft!=="unknown")f+=c+"scrollX="+Math.round(d.object.scrollLeft)+c+"scrollY="+Math.round(d.object.scrollTop)+c+"width="+Math.round(d.object.clientWidth)+c+"height="+Math.round(d.object.clientHeight);f+=c+"widgetX="+Math.round(m-v)+c+"widgetY="+Math.round(p-U)}m=r.button(l);if(!m)if(r.buttons&1)m=1;else if(r.buttons&2)m=2;else if(r.buttons&4)m=4;f+=c+"button="+m;if(typeof l.keyCode!=="undefined"&&typeof l.keyCode!=="unknown")f+=c+"keyCode="+l.keyCode;if(typeof l.type==="string"){m=
0;if(typeof l.charCode!=="undefined"){if(l.type==="keypress")m=l.charCode}else if(l.type==="keypress")m=l.keyCode;f+=c+"charCode="+m}if(typeof l.altKey!=="undefined"&&typeof l.altKey!=="unknown"&&l.altKey)f+=c+"altKey=1";if(typeof l.ctrlKey!=="undefined"&&typeof l.ctrlKey!=="unknown"&&l.ctrlKey)f+=c+"ctrlKey=1";if(typeof l.metaKey!=="undefined"&&typeof l.metaKey!=="unknown"&&l.metaKey)f+=c+"metaKey=1";if(typeof l.shiftKey!=="undefined"&&typeof l.shiftKey!=="unknown"&&l.shiftKey)f+=c+"shiftKey=1";
if(typeof l.touches!=="undefined")f+=qa(c+"touches",l.touches,C);if(typeof l.targetTouches!=="undefined")f+=qa(c+"ttouches",l.targetTouches,C);if(typeof l.changedTouches!=="undefined")f+=qa(c+"ctouches",l.changedTouches,C);if(typeof l.scale!=="undefined"&&typeof l.scale!=="unknown"&&l.scale)f+=c+"scale="+l.scale;if(typeof l.rotation!=="undefined"&&typeof l.rotation!=="unknown"&&l.rotation)f+=c+"rotation="+l.rotation;d.data=f;return d}function Ka(){for(var d="",c=false,f=0;f<I.length;++f){c=c||I[f].feedback;
d+=I[f].data;var l=f>0?"&e"+f:"&";if(I[f].evAckId<W)d+=l+"evAckId="+I[f].evAckId}Ma=I;I=[];return{feedback:c,result:d}}function ya(d){Z=true;Ia=d;if(Ea){clearInterval(Ea);Ea=null}if(K){clearTimeout(K);K=null}ma.cancel();d=$("#Wt-timers");d.size()>0&&r.setHtml(d.get(0),"",false)}function La(){r.history._initTimeout();Fa==0&&ra(null,"keepAlive",null,false)}function Ga(d){if(!r.isIEMobile)document.title=d}function h(d){if(!Ra){if(d){if(!window._$_APP_CLASS_$_LoadWidgetTree)return;r.history.initialize("Wt-history-field",
"Wt-history-iframe",Sa)}if(!("activeElement"in document)){function c(l){if(l&&l.target)document.activeElement=l.target==document?null:l.target}function f(){document.activeElement=null}document.addEventListener("focus",c,true);document.addEventListener("blur",f,true)}$(document).mousedown(r.mouseDown).mouseup(r.mouseUp);r.history._initialize();S();Ra=true;d&&window._$_APP_CLASS_$_LoadWidgetTree();Z||Ea||(Ea=setInterval(La,_$_KEEP_ALIVE_$_000))}}function za(d){clearTimeout(d);document.body.style.cursor=
"auto";if(ia!=null){try{ia()}catch(c){}ia=null}}function sa(){document.body.style.cursor="wait";ia=hideLoadingIndicator;showLoadingIndicator()}function ka(){var d=Date.now(),c=-1;for(var f in na)if(na.hasOwnProperty(f)){if(d-na[f].time>=_$_INDICATOR_TIMEOUT_$_){ia==null&&sa();return}var l=parseInt(f,10);if(l>c)c=l}Na=c+1;document.body.style.cursor="auto";if(ia!=null){try{ia()}catch(p){}ia=null}}function da(d){Ta=d}function la(){E._p_.autoJavaScript()}function V(d){if(d){d="(function() {"+d+"})();";
window.execScript?window.execScript(d):window.eval(d)}E==window._$_APP_CLASS_$_&&la()}function fa(){y.socket.send("&signal=none&connected="+W);y.state=3}function ga(d,c,f){if(D)D.onStatusChange("connectionStatus",d==0?1:0);if(!Z)if(Ja)setTimeout(function(){ga(d,c,f)},50);else{if(d==0){r.resolveRelativeAnchors();_$_$if_CATCH_ERROR_$_();try{_$_$endif_$_();V(c);_$_$if_CATCH_ERROR_$_()}catch(l){var p=l.description||l.message,m={exception_code:l.code,exception_description:p,exception_js:c};m.stack=l.stack||
l.stacktrace;k(m,"Wt internal error; code: "+l.code+", description: "+p);throw l;}_$_$endif_$_();f&&za(f)}else I=Ma.concat(I);Ma=[];if(K){clearTimeout(K);K=null}F=null;if(d>0)++Fa;else Fa=0;if(!Z){y.state==2&&fa();if(Ta||I.length>0)if(d==1){p=Math.min(12E4,Math.exp(Fa)*500);aa=setTimeout(function(){n()},p)}else aa==null&&n()}}}function Aa(d){ua=d.indexOf("://")!=-1||d[0]=="/"?d:Sa+d;ma&&ma.setUrl(d)}function Ba(){F.abort();K=F=null;Z||n()}function T(d){D=d;D.status={};D.status.connectionStatus=0;
D.status.websocket=false;D.onStatusChange=function(c,f){var l=D.status[c];if(l!=f){D.status[c]=f;D.onChange(c,l,f)}}}function ra(d,c,f,l){if(!Oa){Oa=true;r.checkReleaseCapture(d,f);_$_$if_STRICTLY_SERIALIZED_EVENTS_$_();if(!F){_$_$endif_$_();var p={},m=I.length;p.object=d;p.signal=c;p.event=window.fakeEvent||f;p.feedback=l;p.evAckId=W;I[m]=xa(p,m);a();V();_$_$if_STRICTLY_SERIALIZED_EVENTS_$_()}_$_$endif_$_();Oa=false}}function ca(){y.keepAlive&&clearInterval(y.keepAlive);y.keepAlive=setInterval(function(){var d=
y.socket;if(d.readyState==1)d.send("&signal=ping");else{clearInterval(y.keepAlive);y.keepAlive=null}},_$_SERVER_PUSH_TIMEOUT_$_)}function a(){if(Z){if(Ia){if(confirm(Ia))document.location=document.location;Ia=null}}else{_$_$if_WEB_SOCKETS_$_();if(y.state!=4)if(typeof window.WebSocket==="undefined"&&typeof window.MozWebSocket==="undefined")y.state=4;else{var d=y.socket;if(d==null||d.readyState>1)if(d!=null&&y.state==0)y.state=4;else{function c(){if(!Z){++y.reconnectTries;var p=Math.min(12E4,Math.exp(y.reconnectTries)*
500);setTimeout(function(){a()},p)}}var f;if(ua.indexOf("://")!=-1)f="ws"+ua.substr(4);else{f=ua.substr(ua.indexOf("?"));f="ws"+location.protocol.substr(4)+"//"+location.host+_$_WS_PATH_$_+f}f+="&request=ws";var l=_$_WS_ID_$_;if(l.length>0)f+="&wsid="+l;y.socket=typeof window.WebSocket!=="undefined"?(d=new WebSocket(f)):(d=new MozWebSocket(f));y.state=1;y.keepAlive&&clearInterval(y.keepAlive);y.keepAlive=null;d.onmessage=function(p){var m=null;if(y.state==1)if(p.data=="connect"){if(F!=null&&K!=null){clearTimeout(K);
K=null;F.abort();F=null}if(F)y.state=2;else fa()}else{console.log("WebSocket: was expecting a connect?");console.log(p.data);return}else{if(D){D.onStatusChange("websocket",true);D.onStatusChange("connectionStatus",1)}y.state=3;m=p.data}y.reconnectTries=0;m!=null&&ga(0,m,null)};d.onerror=function(){D&&D.onStatusChange("websocket",false);if(y.reconnectTries==3&&y.state==0)y.state=4;c()};d.onclose=function(){D&&D.onStatusChange("websocket",false);if(y.reconnectTries==3&&y.state==0)y.state=4;c()};d.onopen=
function(){if(D){D.onStatusChange("websocket",true);D.onStatusChange("connectionStatus",1)}ca()}}if(d.readyState==1&&d.state==3){ca();n();return}}_$_$endif_$_();if(F!=null&&K!=null){clearTimeout(K);K=null;F.abort();F=null}if(F==null)if(aa==null){aa=setTimeout(function(){n()},r.updateDelay);Ua=(new Date).getTime()}else if(Fa){clearTimeout(aa);aa=null;n()}else if((new Date).getTime()-Ua>r.updateDelay){clearTimeout(aa);aa=null;n()}}}function b(d,c){Pa=c;W=d;ma.responseReceived(d)}function e(){for(var d=
0;d<arguments.length;++d){var c=arguments[d];if(c in na){clearTimeout(na[c].tm);delete na[c]}}ka()}function g(d){Va=d}function k(d,c){F=ma.sendUpdate("request=jserror&err="+encodeURIComponent(JSON.stringify(d)),false,W,-1);_$_$if_SHOW_ERROR_$_();alert(c);_$_$endif_$_()}function n(){function d(){return"_$_PARAMS_$_"}if(E!=window._$_APP_CLASS_$_)ya(null);else if(!F){aa=null;if(!Z){var c,f,l,p=y.socket!==null&&y.socket.readyState===1&&y.state===3;if(I.length>0){c=Ka();f=c.feedback?setTimeout(p?ka:sa,
_$_INDICATOR_TIMEOUT_$_):null;l=false}else{c={result:"&signal=poll"};f=null;l=true}p||(c.result+="&ackId="+W);c.result+="&pageId="+Va;if(Pa){var m="",v=$("#"+Pa).get(0);if(v)for(v=v.parentNode;!r.hasTag(v,"BODY");v=v.parentNode)if(v.id){if(m!="")m+=",";m+=v.id}c.result+="&ackPuzzle="+encodeURIComponent(m)}m=d();if(m.length>0)c.result+="&Wt-params="+encodeURIComponent(m);if(p){F=null;if(!l){if(f){l=Na;na[l]={time:Date.now(),tm:f};++Na;c.result+="&wsRqId="+l}y.socket.send(c.result)}}else{if(F)try{throw new Error("responsePending is true before comm.sendUpdate");
}catch(C){c=C.description||C.message;f={exception_description:c};f.stack=C.stack||C.stacktrace;k(f,"Wt internal error; description: "+c);throw C;}K=l?setTimeout(Ba,_$_SERVER_PUSH_TIMEOUT_$_):null;F=1;F=ma.sendUpdate("request=jsupdate"+c.result,f,W,-1)}}}}function o(d,c,f){if(c==-1)c=d.offsetWidth;if(f==-1)f=d.offsetHeight;if(typeof d.wtWidth==="undefined"||d.wtWidth!=c||typeof d.wtHeight==="undefined"||d.wtHeight!=f){d.wtWidth=c;d.wtHeight=f;c>=0&&f>=0&&q(d,"resized",Math.round(c),Math.round(f))}}
function q(d,c){var f={},l=I.length;f.signal="user";f.id=typeof d==="string"?d:d==E?"app":d.id;if(typeof c==="object"){f.name=c.name;f.object=c.eventObject;f.event=c.event}else{f.name=c;f.object=f.event=null}f.args=[];for(var p=2;p<arguments.length;++p){var m=arguments[p];m=m===false?0:m===true?1:m&&m.toDateString?m.toDateString():m;f.args[p-2]=m}f.feedback=true;f.evAckId=W;I[l]=xa(f,l);a()}function u(d,c,f){var l=function(){var m=r.getElement(d);if(m){if(f)m.timer=setTimeout(m.tm,c);else{m.timer=
null;m.tm=null}m.onclick&&m.onclick()}},p=r.getElement(d);p.timer&&clearTimeout(p.timer);p.timer=setTimeout(l,c);p.tm=l}function w(d,c){setTimeout(function(){if(va[d]===true){Ja=false;c()}else va[d]=c},20);Ja=true}function x(d){if(va[d]!==true){if(typeof va[d]!=="undefined"){Ja=false;va[d]()}va[d]=true}}function B(d,c,f){function l(){if(!m&&!v){v=true;var Y=f===undefined?r.isIE?1:2:f;if(Y>1)B(d,c,Y-1);else{Y={"error-description":"Fatal error: failed loading "+d};k(Y,Y["error-description"]);ya(null)}}}
function p(){if(!m&&!v){m=true;x(d)}}var m=false,v=false;if(c!="")try{m=!eval("typeof "+c+" === 'undefined'")}catch(C){m=false}if(m)x(d);else{var U=document.createElement("script");U.setAttribute("src",d);U.onload=p;U.onerror=l;U.onreadystatechange=function(){var Y=U.readyState;if(Y=="loaded")r.isOpera||r.isIE?p():l();else Y=="complete"&&p()};document.getElementsByTagName("head")[0].appendChild(U)}}function z(d,c){this.callback=c;this.work=d.length;this.images=[];if(d.length==0)c(this.images);else for(c=
0;c<d.length;c++)this.preload(d[c])}function t(d,c){this.callback=c;this.work=d.length;this.arrayBuffers=[];if(d.length==0)c(this.arrayBuffers);else for(c=0;c<d.length;c++)this.preload(d[c],c)}function N(d){ha=d;r.history.register(d,Q)}function H(d){if(d.ieAlternativeExecuted)return"0";E.emit(d.parentNode,"IeAlternative");d.style.width="";d.ieAlternativeExecuted=true;return"0"}function M(d){if(!(r.isIEMobile||d==""))document.documentElement.lang=d}function G(d){window.onbeforeunload=d&&d!=""?function(c){if(c=
c||window.event)c.returnValue=d;return d}:null}function ea(d){Wa=false;d=d==null?$(".Wt-domRoot").get(0).id:d;for(var c=0;c<Qa.length;++c){var f=X?X[d]:null,l=null;if(f)l=f[Qa[c]];f=function(p){return function(m){var v=m||window.event;v=v.target||v.srcElement;if(!v|r.hasTag(v,"DIV")||r.hasTag(v,"BODY")||r.hasTag(v,"HTML"))p&&p(m)}};document["on"+Qa[c]]=l?f(l):null}if(X)for(c in X)document.getElementById(c)||delete X[c]}function s(d,c,f){var l=false;if(!X){X={};l=true}X[c]||(X[c]={});X[c][d]=f;l&&
setTimeout(function(){Wa&&ea(null)},0)}function A(){ma.sendUpdate("request=jsupdate&signal=keepAlive&ackId="+W,false,W,-1)}var E=this,r=_$_WT_CLASS_$_,ta=0,O=0,Sa=_$_DEPLOY_PATH_$_,ha=null,Ha={object:null,sourceId:null,mimeType:null,dropOffsetX:null,dragOffsetY:null,dropTarget:null,objectPrevStyle:null,xy:null},Ca,Xa=1E3,Da=[],Ma=[],I=[],ua,Z=false,Ia=_$_QUITTED_STR_$_,Ra=false,F=null,K=null,Ea=null,Fa=0,Ta=false,aa=null,ia=null,Na=0,na={},y={state:0,socket:null,keepAlive:null,reconnectTries:0},D=
null;Aa(_$_SESSION_URL_$_);var ma=r.initAjaxComm(ua,ga),Oa=false,Ua,W=_$_ACK_UPDATE_ID_$_,Pa=null,Va=0,va={},Ja=false;z.prototype.preload=function(d){var c=new Image;this.images.push(c);c.onload=z.prototype.onload;c.onerror=z.prototype.onload;c.onabort=z.prototype.onload;c.imagePreloader=this;c.src=d};z.prototype.onload=function(){var d=this.imagePreloader;--d.work==0&&d.callback(d.images)};z.prototype.cancel=function(){for(var d=this.images,c=0;c<d.length;++c){d[c].onload=function(){};d[c].onerror=
function(){};d[c].onabort=function(){}}this.callback=function(){}};t.prototype.preload=function(d,c){var f=new XMLHttpRequest;f.open("GET",d,true);f.responseType="arraybuffer";f.arrayBuffers=this.arrayBuffers;f.preloader=this;f.index=c;f.uri=d;f.onload=function(){console.log("XHR load buffer "+this.index+" from uri "+this.uri);this.arrayBuffers[this.index]=this.response;this.preloader.afterLoad()};f.onerror=t.prototype.afterload;f.onabort=t.prototype.afterload;f.send()};t.prototype.afterLoad=function(){--this.work==
0&&this.callback(this.arrayBuffers)};window.onunload=function(){if(!Z){E.emit(E,"Wt-unload");a();n()}};var Wa=true,X=null,Qa=["keydown","keyup","keypress"];this._p_={ieAlternative:H,loadScript:B,onJsLoad:w,setTitle:Ga,setLocale:M,update:ra,quit:ya,setSessionUrl:Aa,setFormObjects:function(d){Da=d},saveDownPos:P,addTimerEvent:u,load:h,setServerPush:da,touchStart:ba,touchEnded:oa,dragStart:wa,dragDrag:ja,dragEnd:pa,capture:r.capture,enableInternalPaths:N,onHashChange:Q,setHash:J,ImagePreloader:z,ArrayBufferPreloader:t,
doAutoJavaScript:la,autoJavaScript:function(){},response:b,wsRqsDone:e,setPage:g,setCloseMessage:G,setConnectionMonitor:T,updateGlobal:ea,bindGlobal:s,refreshCookie:A,propagateSize:o};this.WT=_$_WT_CLASS_$_;this.emit=q});window._$_APP_CLASS_$_SignalEmit=_$_APP_CLASS_$_.emit;window._$_APP_CLASS_$_OnLoad=function(){_$_APP_CLASS_$_._p_.load()};
